<?php

declare (strict_types=1);

namespace App\Model;

use Hyperf\Database\Model\Relations\HasOne;
use Hyperf\DbConnection\Model\Model;

/**
 * @property int $id
 * @property string $account
 * @property string $password
 * @property string $mobile
 * @property int $platform
 * @property string $openid
 * @property string $union_id
 * @property int $status
 * @property int $verify_id
 * @property \Carbon\Carbon $created_at
 * @property \Carbon\Carbon $updated_at
 */
class QmGameAccount extends Model {
    /**
     * The table associated with the model.
     *
     * @var string
     */
    protected $table = 'qm_game_account';
    /**
     * The attributes that are mass assignable.
     *
     * @var array
     */
    protected $fillable = [];
    /**
     * The attributes that should be cast to native types.
     *
     * @var array
     */
    protected $casts = ['id' => 'integer', 'platform' => 'integer', 'status' => 'integer','verify_id' => 'integer'];

    public function verify(): HasOne {
        return $this->hasOne(QmGameAccountVerify::class, 'verify_id', 'id');
    }
}